package file;

import java.io.File;

public class FileDemo {
    public static void main(String[] args) {
        File file = new File("./demo.txt");
        String fileName = file.getName();
        System.out.println(fileName);
        Long fileSize = file.length();
        System.out.println(fileSize);
        boolean isRead = file.canRead();
        System.out.println(isRead);
        System.out.println(file.canWrite());
        boolean canLook = file.isHidden();
        System.out.println(canLook);
    }
}
